<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.1.1/css/all.min.css" integrity="sha512-KfkfwYDsLkIlwQp6LFnl8zNdLGxu9YAA1QvwINks4PhcElQSvqcyVLLD9aMhXd13uQjoXtEKNosOWaZqXgel0g==" crossorigin="anonymous" referrerpolicy="no-referrer" />
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.1.1/css/fontawesome.min.css" integrity="sha512-xX2rYBFJSj86W54Fyv1de80DWBq7zYLn2z0I9bIhQG+rxIF6XVJUpdGnsNHWRa6AvP89vtFupEPDP8eZAtu9qA==" crossorigin="anonymous" referrerpolicy="no-referrer" />
    <link rel="stylesheet" href="./style.css" />
    <title>名片管理系统</title>
  </head>
  <body>
  <%
    session.removeAttribute("user");
    session.removeAttribute("currentCard");
    session.removeAttribute("currentRecyle");
    request.setCharacterEncoding("utf-8");
    response.setContentType("text/html;charset=utf-8");
  %>
    <h2>名片管理系统</h2>
    <div class="container" id="container">
      <div class="form-container sign-up-container">
        <form action="/register" method="post">
          <h1>注册</h1>
          <input type="text" placeholder="请输入用户名" id="r_name" name="username"></input>
          <input type="password" placeholder="请输入密码" id="r_pwd" name="password"></input>
          <input type="password" placeholder="请再次输入密码" id="r_rpwd" name="repassword"></input>
          <input type="submit" value="注册" class="btn" id="toRegister"></input>
        </form>
      </div>
      <div class="form-container sign-in-container">
        <form action="/login" method="post">
          <h1>登录</h1>
          <input type="text" placeholder="请输入用户名" id="u_name" name="username"/>
          <input type="password" placeholder="请输入密码" id="u_pwd" name="password"/>
          <input type="text" placeholder="请输入验证码" id="u_code" name="verCode"/><span style="display: block;vertical-align: middle" id="checkCode"><img src="/captcha" width="130px" height="48px" id="code_img"/></span>
          <input type="submit" value="登录" class="btn" id="toLogin"></input>
        </form>
      </div>
      <div class="overlay-container">
        <div class="overlay">
          <div class="overlay-panel overlay-left">
            <h1>欢迎回来!</h1>
            <button class="ghost" id="signIn">登录</button>
          </div>
          <div class="overlay-panel overlay-right">
            <h1>你好，朋友</h1>
            <button class="ghost" id="signUp">注册</button>
          </div>
        </div>
      </div>
    </div>

    <script src="./script.js"></script>
  </body>
</html>